<?php

use Illuminate\Support\Facades\DB;
use App\Tools\Common;

$router = app('router');

$router->get('sms', function () {
    return 'sms';
});

$router->get('sms/test', function () {
    app('smsService')->sendValidSMS('13311187812', 'login');
});

// 短信管理 admin
$router->group(['namespace' => 'Packages\Sms\Controllers\Admin', 'prefix' => 'api/common'], function () use ($router) {
    $router->post('/sms/code', 'SmsController@smsCode');
});

// 短信管理 client
$router->group(['namespace' => 'Packages\Sms\Controllers\Client', 'prefix' => 'web/common'], function () use ($router) {
    $router->post('/sms/code', 'SmsController@smsCode');
});
